#ifndef __CXXCALL_ABI_HPP__
#define __CXXCALL_ABI_HPP__   1

#if defined (__i386) || defined (__i386__) || defined (_M_IX86)
#  define CXXCALL_I386
#endif

#if defined (__amd64) || defined (__amd64__) ||   \
    defined (__x86_64) || defined (__x86_64__) ||   \
    defined (_M_X64) || defined (_M_AMD64)
#  define CXXCALL_AMD64
#endif

#if defined (__arm__) || defined (__thumb__) || defined (_M_ARM)
#  define CXXCALL_ARM32
#endif

#if defined (__aarch64__) || defined (_M_ARM64)
#  define CXXCALL_ARM64
#endif

#if defined (__mips__) || defined (__mips)
#  define CXXCALL_MIPS
#  if _MIPS_SIM == _ABIN32
#    undef __mipsn32__
#    define __mipsn32__
#  endif

#  if defined (_MIPS_SZLONG) && _MIPS_SZLONG == 64
#    define CXXCALL_MIPS64
#  else
#    define CXXCALL_MIPS32
#  endif
#endif   // mips.

#if defined (__powerpc) || defined (__ppc__) || defined (_ARCH_PPC)
#  define CXXCALL_PPC32
#endif

#if defined (__powerpc64__) || defined (__ppc64__)
#  define CXXCALL_PPC64
#endif

#if defined (__ILP32__) || defined (_ILP32)
#  define CXXCALL_ILP32
#endif

#if defined (CXXCALL_AMD64) || defined (CXXCALL_ARM64) ||   \
    defined (CXXCALL_MIPS64) || defined (CXXCALL_PPC64)
#  define CXXCALL_WIDE
#endif

#if defined (CXXCALL_ARM32) && !defined (__armhf__) && defined (__ARM_PCS_VFP)
#  define __armhf__
#endif

#endif
